import { setStorage, getStorage } from '../utils/storeg'
export default {
  namespaced: true,
  state () {
    return {
      refToken: getStorage('refToken'),
      token: getStorage('token'),
      phone: getStorage('phone'),
      imgg: getStorage('imgg')
    }
  },
  mutations: {
    huoqurefToken (state, refToken) {
      state.refToken = refToken
      setStorage('refToken', refToken)
    },
    huoquToken (state, token) {
      state.token = token
      setStorage('token', token)
    },
    huoquphone (state, phone) {
      state.phone = phone
      setStorage('phone', phone)
    },
    huoqutupian (state, imgg) {
      state.imgg = imgg
      setStorage('imgg', imgg)
    }
  }
}
